package com.lindroy.androidplayer.viewmodel

import androidx.lifecycle.MutableLiveData
import com.lindroy.androidplayer.base.viewmodel.BaseViewModel
import com.lindroy.androidplayer.extensions.request
import com.lindroy.androidplayer.logic.model.UpdateResp
import com.lindroy.androidplayer.logic.network2.state.ResultState
import com.lindroy.androidplayer.logic.network2.apiService

/**
 * @author Lin
 * @date 2021/5/11
 * @function
 */
class UpdateViewModel: BaseViewModel() {
    val updateLiveData: MutableLiveData<ResultState<UpdateResp>> = MutableLiveData()

    fun reqUpdateInfo(){
        request({ apiService.getUpdateInfo()},updateLiveData)
    }
}